Make It! Camp Report 2018
A View from the Tower, Nov.2018 Update with programs and construction of modules.
The Demmer Library and the Three Lakes Model Railroad Club hosted a Make It! Camp this August at The Fab Lab Three Lakes. Those participating in the camp made a key fob of their own design using Adobe Illustrator with the Epilog Laser and did 3D printing on the first day.
Programming an Arduino microprocessor to control tri colored signal lights on a model railroad layout to simulate lights a railroad engineer would see from their train cab (ABS) was an early introduction to the Arduino and C++ programming.
During the 2017 camp we saw that the students were able to deal with the logic of the block signals on a single track in one direction, so it was planned to give them a more difficult problem programming for bi-directional operation on the layout. After successfully testing their single direction block signal program on the club modules the students were challenged to program bi-directional signal controls.
This required that the Three Lakes Club bring a new modular layout that provided additional track, detection, and signals for bi-directional operation. The club built a few new modules and wired them with DCC and NCE BD-20 detectors that provided detection of a train in any of 7 blocks.
To support this operation required not 4 but 10 tri colored signals be wired onto the modules and connected to the Arduino as well as the 7 detected blocks, a great improvement from the 4 blocks of the last two years. If you count the inputs, there were 7 and the outputs, there were an amazing 30 to control the 10 tri-colored signals. Serial data was shifted out to 7 shift registers which latched the output to the common anode signals.
Last year’s bread board and signals for test with 4 blocks and 12 outputs (4 extra LEDs were available for crossing signals) was used to test the new layout. Resistors were moved to positive pullups as the BD-20 used an open collector to bring the signal wire to ground.
Last year's bread board and signals for test with 4 blocks and 12 outputs
In November 2018 we developed a new direction for programming and teaching a better and faster program operations using the input from blocks and turnouts to provide the address of a set of signal outputs that match the layout configuration.
Simple spread sheet study of the options allows truth tables to be turned into signal controls. This is an example of the signal system that is used to teach in the Fab Lab Three Lakes and uses only 4 detection blocks and outputs to 12 colored LEDs.
*****************************************************************
2018 wiring with 7 inputs and 30 outputs sent in color coded wires to the signals
The BD-20 detectors were wired with 3 wire connections using Power, Ground, and signal wires. DCC power to the main line in each module had a wire run thru the orange transformer to detect current flow to the block and report to the Arduino.
Occupancy and signal status were also reported on a computer screen. The Three Lakes Model Railroad Club put in an amazing amount of work to make the layout ready for the Maker Camp - and they proved it could be done!!! They also brought many different models they had made in the Fab Lab for their model railroad layouts.
First programming of an Arduino microprocessor was to solve the real-world engineering challenge - keeping railroad trains safely separated on a single track. After developing the Truth Table for what color signals should show depending on track occupancy, the students applied the elements of the Truth Table to code that would set the signals depending on how the track was occupied. The program was loaded on to the model railroad Arduino which used 4 inputs from the blocks and 12 outputs to the signals.
Students were given the basic setup of the Arduino program on a desk top editor, but after one signal example the text and then the syntax was removed, and the students had to do the programming to move from a truth table to programming the signals. When they were ready they would bring their programs on a flash drive to the layout and test it. If things did not work out they followed our engineering path to check their work and correct any issues with their programs.
Success in one direction was rewarded with the problem of bi-directional signals protecting trains running in opposite directions from crashing into each other on the single-track sections of the modular layout.
*****************************************************************
Here we see photos of the town with a green signal for a train to enter from the East. Looking carefully, you may see the yellow signal down the track indicating two blocks down the line is occupied.
As the Eastbound train moved into the town from the West end the signal go red blocking any train from entering the town from the East. The yellow signal at the other end of town shows that there is an outbound train two blocks ahead in the other direction.
Here we see the Westbound SOO Line train waiting for a clear signal to head for town.
This image, in motion with sound, was on the NBC 12 news along with other images of the trains and signals while students and Demmer Library Director Erica Brewster explained the activities of the Make It! Camp to viewers.
Demmer Director Brewster did not realize her fantasy of crashing two trains into each other because the student's signal programs protected the train operation.
In years past we have changed the code to disable a block detection allowing for signal error and a potential crash. We would then have the students determine the problem and repair the code.
*****************************************************************
Construction in the North Woods
Bob is working on the installation of sub-roadbed and checking operations.
Jack is squaring the KREG joints for the new modules cut and fitted by Brian, Bob and Paul
**************************************************************
Testing of the new modules in airconditioned workshop
The Layout room has a shelf system that accommodates the modules for up to
18' X 6' modules without their frames.
As the modules got ready for installation work moved to the garage for construction with (3) 4' sections on each side of the new 24" radius end modules which are 6’ X 30”.
Fitted with foam to support the track foam is placed into the wooden structure
Careful adjustments will allow the Woodboro and Starks Models will be displayed on the 32" depth modules. The overall size 6' by 17'.
Bob checking out the modules assembled at the Fab Lab Three Lakes.
A BD20 is one of 7 wired for dection of the trains by detection of current flow.
Testing the modules in the garage with track detection on the main line.
Three trains in two directions pass in town as the passing track was not finished.
***************************************************************
Make It! 2016 report (Click Here)
Additional information may be found on the Facebook pages below:
Link to Library Facebook Make It! Camp
Check out other Three Lakes Model Railroad Club activities at the Fab Lab.
Update 10/14/19